putExternalTypedJson

suspend fun <T> putExternalTypedJson(url: String, data: Any, additionalHeaders: Map<String, String> = emptyMap()): JSTypedHttpResponse<T>

PUT JSON stringified data and get a JSON response, casting it to the requested type in JS. T should be an external interface, no type checking is done.

data will be JSON stringified using JS methods.

404 will be mapped to null.

Sources

js source
Link copied to clipboard